package com.star.warmwinter.module.user.viewModel;

import android.databinding.BaseObservable;
import android.databinding.Bindable;

import com.star.warmwinter.BR;
import com.star.warmwinter.module.user.viewCtrl.CommonLoginCtrl;

/**
 * Author: blackbai11
 * Date: 2018/5/31
 * Description: 通用登录页面模型({@link CommonLoginCtrl})
 */
public class CommonLoginVM extends BaseObservable {

    private String phone;
    private String pwd;
    private String pwd2;//确认密码
    private String code;
    private boolean isProtocolChecked;

    @Bindable
    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
        notifyPropertyChanged(BR.phone);
    }

    @Bindable
    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
        notifyPropertyChanged(BR.pwd);
    }

    @Bindable
    public String getPwd2() {
        return pwd2;
    }

    public void setPwd2(String pwd2) {
        this.pwd2 = pwd2;
        notifyPropertyChanged(BR.pwd2);
    }

    @Bindable
    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
        notifyPropertyChanged(BR.code);
    }

    @Bindable
    public boolean isProtocolChecked() {
        return isProtocolChecked;
    }

    public void setProtocolChecked(boolean protocolChecked) {
        isProtocolChecked = protocolChecked;
        notifyPropertyChanged(BR.protocolChecked);
    }
}
